package models_main

import (
	"fmt"
	"longmen/server/pkg/db/mysql/models"
	"time"
)

type Smscode struct {
	Id         int       `json:"id" gorm:"primaryKey;autoIncrement"`
	Mobile     string    `json:"mobile"`      //varchar(20) DEFAULT NULL,
	Code       string    `json:"code"`        //int(6) DEFAULT NULL,
	Status     int       `json:"status"`      //int(1) DEFAULT '0' COMMENT '0-未使用 1-已使用',
	CreateTime time.Time `json:"create_time"` //datetime DEFAULT NULL,
	RequestIp  string    `json:"request_ip"`  //varchar(255) DEFAULT NULL COMMENT '请求ip',
}

func (Smscode) TableName() string {
	return fmt.Sprintf("%ssmscode", models.Prefix)
}
